home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
FM Towns: Free Software Collection 4
/
FM Towns Free Software Collection 4 - Disc 1.iso
/
data
/
fmgraph
/
g_linpt2.c
< prev
next >
Wrap
Text File
|
1991-10-18
|
837b
|
42 lines
#include <stdio.h>
#include <dos.h>
struct LINEPATTERN {
unsigned type,escno,escln;
char id,reserve;
unsigned size;
unsigned char ptn1,ptn2;
};
extern unsigned char gds_fshift;
extern unsigned gds_wrkoff;
extern unsigned gds_wrkseg;
int g_linepattern2(char lineid,unsigned char form1,unsigned char form2)
{
union REGS reg;
struct SREGS seg;
struct {
unsigned len;
struct LINEPATTERN lptn;
} gdata;
segread(&seg);
reg.h.ah=gds_fshift+0x0f;
reg.x.di=(unsigned)&gdata;
seg.ds=seg.ss;
gdata.len=12;
gdata.lptn.type=0x602a;
gdata.lptn.escno=4;
gdata.lptn.escln=6;
gdata.lptn.id=lineid;
gdata.lptn.reserve=0;
gdata.lptn.size=16;
gdata.lptn.ptn1=form1;
gdata.lptn.ptn2=form2;
reg.x.bx=gds_wrkoff;
seg.es=gds_wrkseg;
int86x(0x92,®,®,&seg);
return (int)reg.h.ah;
}